package fvortex.flute;

import net.minecraft.client.settings.KeyBinding;
import net.minecraftforge.fml.client.registry.ClientRegistry;
import org.lwjgl.input.Keyboard;

/**
 * Instantiate this in init method of ClientProxy
 */
public class KeyRegistry {

    public static final int NOTE_NUMBER = 7;
    public static KeyBinding[] fluteNote = new KeyBinding[NOTE_NUMBER];
    public static final String[] fluteKeyDesc =
            {
                    "C","D","E","F","G","A","B"
            };
    public static final int[] fluteKeyDefault =
            {
                    Keyboard.KEY_A,
                    Keyboard.KEY_S,
                    Keyboard.KEY_D,
                    Keyboard.KEY_F,
                    Keyboard.KEY_G,
                    Keyboard.KEY_H,
                    Keyboard.KEY_J

            };

    public KeyRegistry()
    {
//        fluteFreeModeKeys();
    }

    public void fluteFreeModeKeys()
    {
        for (int i = 0; i < NOTE_NUMBER; i++) {

            KeyRegistry.fluteNote[i] = new KeyBinding("key.flute.note" + fluteKeyDesc[i],
                    fluteKeyDefault[i], "key.categories.flute");
            ClientRegistry.registerKeyBinding(KeyRegistry.fluteNote[i]);
        }
    }
}
